﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Masters/FrontEnd.Master" AutoEventWireup="true"
    CodeBehind="TalentDeclareList.aspx.cs" Inherits="iOak.Web.TalentDeclareList" %>

<%@ Register Src="~/Modules/PagerControl.ascx" TagName="PagerControl" TagPrefix="iOak" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <script type="text/javascript">

        function DownLoadSummery(id) {
            window.open("/Report/SummaryReports.aspx?campaignId=" + id, "abc", "height=80,width=300,left=" + (screen.width / 2 - 150) + ",top=" + (screen.height / 2 - 40) + ",toolbar=no,menubar=no,scrollbars=no,resizable=no,location=no,status=no")
        }

        function DownLoadApply(id) {
            window.open("/Report/ApplyReports.aspx?campaignId=" + id, "abc", "height=80,width=300,left=" + (screen.width / 2 - 150) + ",top=" + (screen.height / 2 - 40) + ",toolbar=no,menubar=no,scrollbars=no,resizable=no,location=no,status=no")
        }

        function submitClick(id, allowSubmit) {
            if (allowSubmit) {
                jConfirm("确定要提交申请书吗？", function () {
                    $('#<%=hidCampaignId.ClientID %>').val(id);
                    $('#<%=btnPostBack.ClientID %>').click();
                });
            }
            else {
                jAlert("不能提交申请！因为您的企业未通过审核，请与新区人才开发办公室联系。");
            }
            return false;
        }

        function addPaperClick(id) {
            location.href = "ResumeEdit.aspx?campaignId=" + id;
        }

        function candidateClick(id) {
            location.href = "CandidateList.aspx?campaignId=" + id;
        }

    </script>
    <div class="content">
        <div class="left_bar">
            <div class="left_menu">
                <div class="left_menu_top">
                    视图
                </div>
                <div class="sub_menu">
                    <ul>
                        <li>
                            <asp:LinkButton ID="lnkAll" runat="server" Text="所有" OnClick="lnkAll_Click"></asp:LinkButton>
                        </li>
                        <li>
                            <asp:LinkButton ID="lnkNoDeclaration" runat="server" Text="未申报" OnClick="lnkNoDeclaration_Click"></asp:LinkButton>
                        </li>
                        <li>
                            <asp:LinkButton ID="lnkYesDeclaration" runat="server" Text="已申报" OnClick="lnkYesDeclaration_Click"></asp:LinkButton>
                        </li>
<%--                        <li>
                            <asp:LinkButton ID="lnkChecking" runat="server" Text="审核中" OnClick="lnkChecking_Click"></asp:LinkButton>
                        </li>--%>
                        <li>
                            <asp:LinkButton ID="lnkAudit" runat="server" Text="已审核" OnClick="lnkAudit_Click"></asp:LinkButton>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
        <div class="right_bar">
            <div class="right_content">
                <table width="100%" border="0" cellspacing="0" cellpadding="0" style="background-color: #fff;">
                    <tr>
                        <td width="7" align="left" valign="top">
                            <img src="/images/tab-j_01.jpg" width="7" height="7" />
                        </td>
                        <td>
                            <div class="now-pac">
                                您现在的位置：：<a href="#">人才申报</a> &gt; 人才申报列表</div>
                        </td>
                        <td width="7" align="right" valign="top">
                            <img src="/images/tab-j_02.jpg" width="7" height="7" />
                        </td>
                    </tr>
                    <tr>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            <div style="border: 1px solid #ccc">
                                <div style="border: 1px solid #fff">
                                    <table width="100%" border="0" cellspacing="0" cellpadding="0" class="tab1">
                                        <tr>
                                            <td>
                                                <div class="table-header">
                                                    <div class="table-header_name">
                                                        申报列表</div>
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <asp:GridView runat="server" ID="gvTalentDeclareList" Width="100%" AutoGenerateColumns="false"
                                                    OnRowDataBound="gvTalentDeclareList_RowDataBound" CssClass="tab1">
                                                    <HeaderStyle CssClass="tab1_green" />
                                                    <RowStyle CssClass="itemRow" />
                                                    <AlternatingRowStyle CssClass="alternatingRow" />
                                                    <Columns>
                                                        <asp:BoundField HeaderText="名称" DataField="Subject" ItemStyle-HorizontalAlign="Left" />
                                                        <asp:TemplateField HeaderText="截止日期" ItemStyle-Width="80px">
                                                            <ItemTemplate>
                                                                <%# ((DateTime)DataBinder.Eval(Container.DataItem, "EndDate")).ToString("yyyy-MM-dd")%>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField HeaderText="候选简历" ItemStyle-HorizontalAlign="Right" ItemStyle-Width="60px">
                                                            <ItemTemplate>
                                                                <asp:Label runat="server" ID="lblResumeNumber"></asp:Label>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField HeaderText="状态" ItemStyle-Width="60px">
                                                            <ItemTemplate>
                                                                <asp:Label runat="server" ID="lblStatus"></asp:Label>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField HeaderText="操作" ItemStyle-Width="40px">
                                                            <ItemTemplate>
                                                                <asp:Image runat="server" ID="imgOptionMenu" ImageUrl="~/Images/opetionMenu.gif"
                                                                    onclick="$('.optionMenu').show()" Style="cursor: pointer" />
                                                                <ajaxToolkit:PopupControlExtender ID="PopupControlExtender2" runat="server" TargetControlID="imgOptionMenu"
                                                                    PopupControlID="pnlOptionMenu" Position="Bottom" />
                                                                <asp:Panel ID="pnlOptionMenu" runat="server" Style="display: none">
                                                                    <div class="optionMenu">
                                                                        <asp:PlaceHolder ID="phPreview" runat="server">
                                                                            <div onclick="$('.optionMenu').hide();candidateClick('<%#DataBinder.Eval(Container.DataItem, "CampaignId") %>');">
                                                                                浏览候选人
                                                                            </div>
                                                                        </asp:PlaceHolder>
                                                                        <asp:PlaceHolder ID="phAdd" runat="server">
                                                                            <div onclick="$('.optionMenu').hide();addPaperClick('<%#DataBinder.Eval(Container.DataItem, "CampaignId") %>')">
                                                                                添加候选人
                                                                            </div>
                                                                        </asp:PlaceHolder>
                                                                        <asp:PlaceHolder ID="phSubmit" runat="server">
                                                                            <div runat="server" id="divSubmit">
                                                                                提交申请书
                                                                            </div>
                                                                        </asp:PlaceHolder>
                                                                        <asp:PlaceHolder ID="phDownLoadSummery" runat="server">
                                                                            <div onclick="$('.optionMenu').hide();DownLoadSummery('<%#DataBinder.Eval(Container.DataItem, "CampaignId") %>')">
                                                                                下载汇总表
                                                                            </div>
                                                                        </asp:PlaceHolder>
                                                                        <asp:PlaceHolder ID="phDownLoadApply" runat="server">
                                                                            <div onclick="$('.optionMenu').hide();DownLoadApply('<%#DataBinder.Eval(Container.DataItem, "CampaignId") %>')">
                                                                                下载补贴申请书
                                                                            </div>
                                                                        </asp:PlaceHolder>
                                                                    </div>
                                                                </asp:Panel>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                    </Columns>
                                                </asp:GridView>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <iOak:PagerControl runat="server" ID="pagerControl" PageIndexChange="pagerControl_PageIndexChange">
                                                </iOak:PagerControl>
                                            </td>
                                        </tr>
                                    </table>
                                </div>
                            </div>
                        </td>
                    </tr>
                </table>
            </div>
        </div>
    </div>
    <asp:HiddenField ID="hidCampaignId" runat="server" />
    <asp:Button ID="btnPostBack" runat="server" CssClass="hidden" OnClick="btnPostBack_Click" />
</asp:Content>
